﻿using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ERP.Domain.Warehouse
{
    /// <summary>
    /// 库存交易记录实体
    /// </summary>
    public class InventoryTransaction
    {
        // <summary>
        /// 主键ID
        /// </summary>
        [Key]
        public int Id { get; set; }

        /// <summary>
        /// 产品名称
        /// </summary>
        [Required]
        [StringLength(100)]
        public string ProductName { get; set; }

        /// <summary>
        /// 产品编号
        /// </summary>
        [Required]
        [StringLength(50)]
        public string ProductNumber { get; set; }
        /// <summary>
        /// 规格
        /// </summary>
        public string Specification { get; set; }
        /// <summary>
        /// 单位
        /// </summary>
        public string Unit { get; set; }

        /// <summary>
        /// 库房名称
        /// </summary>
        [Required]
        [StringLength(100)]
        public string WarehouseName { get; set; }

        /// <summary>
        /// 库区名称
        /// </summary>
        [StringLength(100)]
        public string WarehouseAreaName { get; set; }

        /// <summary>
        /// 库位名称
        /// </summary>
        [StringLength(100)]
        public string BinLocationName { get; set; }

        /// <summary>
        /// 出入库类别
        /// </summary>
        [Required]
        [StringLength(50)]
        public string TransactionType { get; set; }

        /// <summary>
        /// 数量
        /// </summary>
        public decimal? Quantity { get; set; }

        /// <summary>
        /// 单价
        /// </summary>
        public decimal? UnitPrice { get; set; }

        /// <summary>
        /// 出入库时间
        /// </summary>
        public DateTime? TransactionTime { get; set; }

        /// <summary>
        /// 申请人
        /// </summary>
        [StringLength(50)]
        public string Applicant { get; set; }

        /// <summary>
        /// 备注说明
        /// </summary>
        [StringLength(500)]
        public string Remarks { get; set; }
    }
}
